package com.tangsm.spring.boot.fluent.mybatis.entity;

import cn.org.atool.fluent.mybatis.annotation.FluentMybatis;
import cn.org.atool.fluent.mybatis.annotation.TableField;
import cn.org.atool.fluent.mybatis.annotation.TableId;
import cn.org.atool.fluent.mybatis.base.RichEntity;
import java.util.Date;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

/**
 * RoleEntity: 数据映射实体定义
 *
 * @author Powered By Fluent Mybatis
 */
@SuppressWarnings({"rawtypes", "unchecked"})
@Data
@Accessors(
    chain = true
)
@EqualsAndHashCode(
    callSuper = false
)
@AllArgsConstructor
@NoArgsConstructor
@FluentMybatis(
    table = "sys_role",
    schema = "nft_admin",
    desc = "角色信息表"
)
public class RoleEntity extends RichEntity {
  private static final long serialVersionUID = 1L;

  @TableId(
      value = "role_id",
      desc = "角色ID"
  )
  private Long roleId;

  @TableField(
      value = "create_by",
      desc = "创建者"
  )
  private String createBy;

  @TableField(
      value = "create_time",
      desc = "创建时间"
  )
  private Date createTime;

  @TableField(
      value = "data_scope",
      desc = "数据范围（1：全部数据权限 2：自定数据权限 3：本部门数据权限 4：本部门及以下数据权限）"
  )
  private String dataScope;

  @TableField(
      value = "del_flag",
      desc = "删除标志（0代表存在 2代表删除）"
  )
  private String delFlag;

  @TableField(
      value = "dept_check_strictly",
      desc = "部门树选择项是否关联显示"
  )
  private Boolean deptCheckStrictly;

  @TableField(
      value = "menu_check_strictly",
      desc = "菜单树选择项是否关联显示"
  )
  private Boolean menuCheckStrictly;

  @TableField(
      value = "remark",
      desc = "备注"
  )
  private String remark;

  @TableField(
      value = "role_key",
      desc = "角色权限字符串"
  )
  private String roleKey;

  @TableField(
      value = "role_name",
      desc = "角色名称"
  )
  private String roleName;

  @TableField(
      value = "role_sort",
      desc = "显示顺序"
  )
  private Integer roleSort;

  @TableField(
      value = "status",
      desc = "角色状态（0正常 1停用）"
  )
  private String status;

  @TableField(
      value = "update_by",
      desc = "更新者"
  )
  private String updateBy;

  @TableField(
      value = "update_time",
      desc = "更新时间"
  )
  private Date updateTime;

  @Override
  public final Class entityClass() {
    return RoleEntity.class;
  }
}
